using System;
using System.Collections.Generic;
using System.Text;

namespace Shifter
{
    class RuleStepPredicate
    {
        public RuleStepPredicate(int val)
        {
            m_value = val;
        }

        private int m_value;
        public int Value
        {
            get { return m_value; }
            set { m_value = value; }
        }

        public Predicate<RuleStep> Match
        {
            get { return isMatch; }
        }

        private bool isMatch(RuleStep rs)
        {
            return (rs.StepNumber == m_value);
        }
    }

    class RulePredicate
    {
        public RulePredicate(String val)
        {
            m_value = val;
        }

        private String m_value;
        public String Value
        {
            get { return m_value; }
            set { m_value = value; }
        }

        public Predicate<Rule> Match
        {
            get { return isMatch; }
        }

        private bool isMatch(Rule r)
        {
            return (r.Name.Equals(m_value));
        }
    }
}
